//===----------------------------------------------------------------------===//
//
// This source file is part of the Soto for AWS open source project
//
// Copyright (c) 2017-2024 the Soto project authors
// Licensed under Apache License v2.0
//
// See LICENSE.txt for license information
// See CONTRIBUTORS.txt for the list of Soto project authors
//
// SPDX-License-Identifier: Apache-2.0
//
//===----------------------------------------------------------------------===//

// THIS FILE IS AUTOMATICALLY GENERATED by https://github.com/soto-project/soto-codegenerator.
// DO NOT EDIT.

#if canImport(FoundationEssentials)
import FoundationEssentials
#else
import Foundation
#endif
@_exported import SotoCore

/// Service object for interacting with AWS SSMContacts service.
///
/// Systems Manager Incident Manager is an incident management console designed to help users mitigate and recover from incidents affecting their Amazon Web Services-hosted applications. An incident is any unplanned interruption or reduction in quality of services. Incident Manager increases incident resolution by notifying responders of impact, highlighting relevant troubleshooting data, and providing collaboration tools to get services back up and running. To achieve the primary goal of reducing the time-to-resolution of critical incidents, Incident Manager automates response plans and enables responder team escalation.
public struct SSMContacts: AWSService {
    // MARK: Member variables

    /// Client used for communication with AWS
    public let client: AWSClient
    /// Service configuration
    public let config: AWSServiceConfig

    // MARK: Initialization

    /// Initialize the SSMContacts client
    /// - parameters:
    ///     - client: AWSClient used to process requests
    ///     - region: Region of server you want to communicate with. This will override the partition parameter.
    ///     - partition: AWS partition where service resides, standard (.aws), china (.awscn), government (.awsusgov).
    ///     - endpoint: Custom endpoint URL to use instead of standard AWS servers
    ///     - middleware: Middleware chain used to edit requests before they are sent and responses before they are decoded 
    ///     - timeout: Timeout value for HTTP requests
    ///     - byteBufferAllocator: Allocator for ByteBuffers
    ///     - options: Service options
    public init(
        client: AWSClient,
        region: SotoCore.Region? = nil,
        partition: AWSPartition = .aws,
        endpoint: String? = nil,
        middleware: AWSMiddlewareProtocol? = nil,
        timeout: TimeAmount? = nil,
        byteBufferAllocator: ByteBufferAllocator = ByteBufferAllocator(),
        options: AWSServiceConfig.Options = []
    ) {
        self.client = client
        self.config = AWSServiceConfig(
            region: region,
            partition: region?.partition ?? partition,
            amzTarget: "SSMContacts",
            serviceName: "SSMContacts",
            serviceIdentifier: "ssm-contacts",
            serviceProtocol: .json(version: "1.1"),
            apiVersion: "2021-05-03",
            endpoint: endpoint,
            variantEndpoints: Self.variantEndpoints,
            errorType: SSMContactsErrorType.self,
            middleware: middleware,
            timeout: timeout,
            byteBufferAllocator: byteBufferAllocator,
            options: options
        )
    }




    /// FIPS and dualstack endpoints
    static var variantEndpoints: [EndpointVariantType: AWSServiceConfig.EndpointVariant] {[
        [.fips]: .init(endpoints: [
            "us-east-1": "ssm-contacts-fips.us-east-1.amazonaws.com",
            "us-east-2": "ssm-contacts-fips.us-east-2.amazonaws.com",
            "us-west-1": "ssm-contacts-fips.us-west-1.amazonaws.com",
            "us-west-2": "ssm-contacts-fips.us-west-2.amazonaws.com"
        ])
    ]}

    // MARK: API Calls

    /// Used to acknowledge an engagement to a contact channel during an incident.
    @Sendable
    @inlinable
    public func acceptPage(_ input: AcceptPageRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> AcceptPageResult {
        try await self.client.execute(
            operation: "AcceptPage", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Used to acknowledge an engagement to a contact channel during an incident.
    ///
    /// Parameters:
    ///   - acceptCode: A 6-digit code used to acknowledge the page.
    ///   - acceptCodeValidation: An optional field that Incident Manager uses to ENFORCE AcceptCode validation when acknowledging an page. Acknowledgement can occur by replying to a page, or when entering the AcceptCode in the console. Enforcing AcceptCode validation causes Incident Manager to verify that the code entered by the user matches the code sent by Incident Manager with the page. Incident Manager can also IGNORE AcceptCode validation. Ignoring AcceptCode validation causes Incident Manager to accept any value entered for the AcceptCode.
    ///   - acceptType: The type indicates if the page was DELIVERED or READ.
    ///   - contactChannelId: The ARN of the contact channel.
    ///   - note: Information provided by the user when the user acknowledges the page.
    ///   - pageId: The Amazon Resource Name (ARN) of the engagement to a contact channel.
    ///   - logger: Logger use during operation
    @inlinable
    public func acceptPage(
        acceptCode: String,
        acceptCodeValidation: AcceptCodeValidation? = nil,
        acceptType: AcceptType,
        contactChannelId: String? = nil,
        note: String? = nil,
        pageId: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> AcceptPageResult {
        let input = AcceptPageRequest(
            acceptCode: acceptCode, 
            acceptCodeValidation: acceptCodeValidation, 
            acceptType: acceptType, 
            contactChannelId: contactChannelId, 
            note: note, 
            pageId: pageId
        )
        return try await self.acceptPage(input, logger: logger)
    }

    /// Activates a contact's contact channel. Incident Manager can't engage a contact until the contact channel has been activated.
    @Sendable
    @inlinable
    public func activateContactChannel(_ input: ActivateContactChannelRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> ActivateContactChannelResult {
        try await self.client.execute(
            operation: "ActivateContactChannel", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Activates a contact's contact channel. Incident Manager can't engage a contact until the contact channel has been activated.
    ///
    /// Parameters:
    ///   - activationCode: The code sent to the contact channel when it was created in the contact.
    ///   - contactChannelId: The Amazon Resource Name (ARN) of the contact channel.
    ///   - logger: Logger use during operation
    @inlinable
    public func activateContactChannel(
        activationCode: String,
        contactChannelId: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> ActivateContactChannelResult {
        let input = ActivateContactChannelRequest(
            activationCode: activationCode, 
            contactChannelId: contactChannelId
        )
        return try await self.activateContactChannel(input, logger: logger)
    }

    /// Contacts are either the contacts that Incident Manager engages during an incident or the escalation plans that Incident Manager uses to engage contacts in phases during an incident.
    @Sendable
    @inlinable
    public func createContact(_ input: CreateContactRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> CreateContactResult {
        try await self.client.execute(
            operation: "CreateContact", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Contacts are either the contacts that Incident Manager engages during an incident or the escalation plans that Incident Manager uses to engage contacts in phases during an incident.
    ///
    /// Parameters:
    ///   - alias: The short name to quickly identify a contact or escalation plan. The contact alias must be unique and identifiable.
    ///   - displayName: The full name of the contact or escalation plan.
    ///   - idempotencyToken: A token ensuring that the operation is called only once with the specified details.
    ///   - plan: A list of stages. A contact has an engagement plan with stages that contact specified contact channels. An escalation plan uses stages that contact specified contacts.
    ///   - tags: Adds a tag to the target. You can only tag resources created in the first Region of your replication set.
    ///   - type: To create an escalation plan use ESCALATION. To create a contact use PERSONAL.
    ///   - logger: Logger use during operation
    @inlinable
    public func createContact(
        alias: String,
        displayName: String? = nil,
        idempotencyToken: String? = CreateContactRequest.idempotencyToken(),
        plan: Plan,
        tags: [Tag]? = nil,
        type: ContactType,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> CreateContactResult {
        let input = CreateContactRequest(
            alias: alias, 
            displayName: displayName, 
            idempotencyToken: idempotencyToken, 
            plan: plan, 
            tags: tags, 
            type: type
        )
        return try await self.createContact(input, logger: logger)
    }

    /// A contact channel is the method that Incident Manager uses to engage your contact.
    @Sendable
    @inlinable
    public func createContactChannel(_ input: CreateContactChannelRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> CreateContactChannelResult {
        try await self.client.execute(
            operation: "CreateContactChannel", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// A contact channel is the method that Incident Manager uses to engage your contact.
    ///
    /// Parameters:
    ///   - contactId: The Amazon Resource Name (ARN) of the contact you are adding the contact channel to.
    ///   - deferActivation: If you want to activate the channel at a later time, you can choose to defer activation. Incident Manager can't engage your contact channel until it has been activated.
    ///   - deliveryAddress: The details that Incident Manager uses when trying to engage the contact channel. The format is dependent on the type of the contact channel. The following are the expected formats:   SMS - '+' followed by the country code and phone number   VOICE - '+' followed by the country code and phone number   EMAIL - any standard email format
    ///   - idempotencyToken: A token ensuring that the operation is called only once with the specified details.
    ///   - name: The name of the contact channel.
    ///   - type: Incident Manager supports three types of contact channels:    SMS     VOICE     EMAIL
    ///   - logger: Logger use during operation
    @inlinable
    public func createContactChannel(
        contactId: String,
        deferActivation: Bool? = nil,
        deliveryAddress: ContactChannelAddress,
        idempotencyToken: String? = CreateContactChannelRequest.idempotencyToken(),
        name: String,
        type: ChannelType,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> CreateContactChannelResult {
        let input = CreateContactChannelRequest(
            contactId: contactId, 
            deferActivation: deferActivation, 
            deliveryAddress: deliveryAddress, 
            idempotencyToken: idempotencyToken, 
            name: name, 
            type: type
        )
        return try await self.createContactChannel(input, logger: logger)
    }

    /// Creates a rotation in an on-call schedule.
    @Sendable
    @inlinable
    public func createRotation(_ input: CreateRotationRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> CreateRotationResult {
        try await self.client.execute(
            operation: "CreateRotation", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Creates a rotation in an on-call schedule.
    ///
    /// Parameters:
    ///   - contactIds: The Amazon Resource Names (ARNs) of the contacts to add to the rotation. The order that you list the contacts in is their shift order in the rotation schedule. To change the order of the contact's shifts, use the UpdateRotation operation.
    ///   - idempotencyToken: A token that ensures that the operation is called only once with the specified details.
    ///   - name: The name of the rotation.
    ///   - recurrence: Information about the rule that specifies when a shift's team members rotate.
    ///   - startTime: The date and time that the rotation goes into effect.
    ///   - tags: Optional metadata to assign to the rotation. Tags enable you to categorize a resource in different ways, such as by purpose, owner, or environment. For more information, see Tagging Incident Manager resources in the Incident Manager User Guide.
    ///   - timeZoneId: The time zone to base the rotation’s activity on in Internet Assigned Numbers Authority (IANA) format. For example: "America/Los_Angeles", "UTC", or "Asia/Seoul". For more information, see the Time Zone Database on the IANA website.  Designators for time zones that don’t support Daylight Savings Time rules, such as Pacific Standard Time (PST) and Pacific Daylight Time (PDT), are not supported.
    ///   - logger: Logger use during operation
    @inlinable
    public func createRotation(
        contactIds: [String],
        idempotencyToken: String? = nil,
        name: String,
        recurrence: RecurrenceSettings,
        startTime: Date? = nil,
        tags: [Tag]? = nil,
        timeZoneId: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> CreateRotationResult {
        let input = CreateRotationRequest(
            contactIds: contactIds, 
            idempotencyToken: idempotencyToken, 
            name: name, 
            recurrence: recurrence, 
            startTime: startTime, 
            tags: tags, 
            timeZoneId: timeZoneId
        )
        return try await self.createRotation(input, logger: logger)
    }

    /// Creates an override for a rotation in an on-call schedule.
    @Sendable
    @inlinable
    public func createRotationOverride(_ input: CreateRotationOverrideRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> CreateRotationOverrideResult {
        try await self.client.execute(
            operation: "CreateRotationOverride", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Creates an override for a rotation in an on-call schedule.
    ///
    /// Parameters:
    ///   - endTime: The date and time when the override ends.
    ///   - idempotencyToken: A token that ensures that the operation is called only once with the specified details.
    ///   - newContactIds: The Amazon Resource Names (ARNs) of the contacts to replace those in the current on-call rotation with. If you want to include any current team members in the override shift, you must include their ARNs in the new contact ID list.
    ///   - rotationId: The Amazon Resource Name (ARN) of the rotation to create an override for.
    ///   - startTime: The date and time when the override goes into effect.
    ///   - logger: Logger use during operation
    @inlinable
    public func createRotationOverride(
        endTime: Date,
        idempotencyToken: String? = nil,
        newContactIds: [String],
        rotationId: String,
        startTime: Date,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> CreateRotationOverrideResult {
        let input = CreateRotationOverrideRequest(
            endTime: endTime, 
            idempotencyToken: idempotencyToken, 
            newContactIds: newContactIds, 
            rotationId: rotationId, 
            startTime: startTime
        )
        return try await self.createRotationOverride(input, logger: logger)
    }

    /// To no longer receive Incident Manager engagements to a contact channel, you can deactivate the channel.
    @Sendable
    @inlinable
    public func deactivateContactChannel(_ input: DeactivateContactChannelRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> DeactivateContactChannelResult {
        try await self.client.execute(
            operation: "DeactivateContactChannel", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// To no longer receive Incident Manager engagements to a contact channel, you can deactivate the channel.
    ///
    /// Parameters:
    ///   - contactChannelId: The Amazon Resource Name (ARN) of the contact channel you're deactivating.
    ///   - logger: Logger use during operation
    @inlinable
    public func deactivateContactChannel(
        contactChannelId: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> DeactivateContactChannelResult {
        let input = DeactivateContactChannelRequest(
            contactChannelId: contactChannelId
        )
        return try await self.deactivateContactChannel(input, logger: logger)
    }

    /// To remove a contact from Incident Manager, you can delete the contact. Deleting a contact removes them from all escalation plans and related response plans. Deleting an escalation plan removes it from all related response plans. You will have to recreate the contact and its contact channels before you can use it again.
    @Sendable
    @inlinable
    public func deleteContact(_ input: DeleteContactRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> DeleteContactResult {
        try await self.client.execute(
            operation: "DeleteContact", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// To remove a contact from Incident Manager, you can delete the contact. Deleting a contact removes them from all escalation plans and related response plans. Deleting an escalation plan removes it from all related response plans. You will have to recreate the contact and its contact channels before you can use it again.
    ///
    /// Parameters:
    ///   - contactId: The Amazon Resource Name (ARN) of the contact that you're deleting.
    ///   - logger: Logger use during operation
    @inlinable
    public func deleteContact(
        contactId: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> DeleteContactResult {
        let input = DeleteContactRequest(
            contactId: contactId
        )
        return try await self.deleteContact(input, logger: logger)
    }

    /// To no longer receive engagements on a contact channel, you can delete the channel from a contact. Deleting the contact channel removes it from the contact's engagement plan. If you delete the only contact channel for a contact, you won't be able to engage that contact during an incident.
    @Sendable
    @inlinable
    public func deleteContactChannel(_ input: DeleteContactChannelRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> DeleteContactChannelResult {
        try await self.client.execute(
            operation: "DeleteContactChannel", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// To no longer receive engagements on a contact channel, you can delete the channel from a contact. Deleting the contact channel removes it from the contact's engagement plan. If you delete the only contact channel for a contact, you won't be able to engage that contact during an incident.
    ///
    /// Parameters:
    ///   - contactChannelId: The Amazon Resource Name (ARN) of the contact channel.
    ///   - logger: Logger use during operation
    @inlinable
    public func deleteContactChannel(
        contactChannelId: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> DeleteContactChannelResult {
        let input = DeleteContactChannelRequest(
            contactChannelId: contactChannelId
        )
        return try await self.deleteContactChannel(input, logger: logger)
    }

    /// Deletes a rotation from the system. If a rotation belongs to more than one on-call schedule, this operation deletes it from all of them.
    @Sendable
    @inlinable
    public func deleteRotation(_ input: DeleteRotationRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> DeleteRotationResult {
        try await self.client.execute(
            operation: "DeleteRotation", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Deletes a rotation from the system. If a rotation belongs to more than one on-call schedule, this operation deletes it from all of them.
    ///
    /// Parameters:
    ///   - rotationId: The Amazon Resource Name (ARN) of the on-call rotation to delete.
    ///   - logger: Logger use during operation
    @inlinable
    public func deleteRotation(
        rotationId: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> DeleteRotationResult {
        let input = DeleteRotationRequest(
            rotationId: rotationId
        )
        return try await self.deleteRotation(input, logger: logger)
    }

    /// Deletes an existing override for an on-call rotation.
    @Sendable
    @inlinable
    public func deleteRotationOverride(_ input: DeleteRotationOverrideRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> DeleteRotationOverrideResult {
        try await self.client.execute(
            operation: "DeleteRotationOverride", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Deletes an existing override for an on-call rotation.
    ///
    /// Parameters:
    ///   - rotationId: The Amazon Resource Name (ARN) of the rotation that was overridden.
    ///   - rotationOverrideId: The Amazon Resource Name (ARN) of the on-call rotation override to delete.
    ///   - logger: Logger use during operation
    @inlinable
    public func deleteRotationOverride(
        rotationId: String,
        rotationOverrideId: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> DeleteRotationOverrideResult {
        let input = DeleteRotationOverrideRequest(
            rotationId: rotationId, 
            rotationOverrideId: rotationOverrideId
        )
        return try await self.deleteRotationOverride(input, logger: logger)
    }

    /// Incident Manager uses engagements to engage contacts and escalation plans during an incident. Use this command to describe the engagement that occurred during an incident.
    @Sendable
    @inlinable
    public func describeEngagement(_ input: DescribeEngagementRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> DescribeEngagementResult {
        try await self.client.execute(
            operation: "DescribeEngagement", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Incident Manager uses engagements to engage contacts and escalation plans during an incident. Use this command to describe the engagement that occurred during an incident.
    ///
    /// Parameters:
    ///   - engagementId: The Amazon Resource Name (ARN) of the engagement you want the details of.
    ///   - logger: Logger use during operation
    @inlinable
    public func describeEngagement(
        engagementId: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> DescribeEngagementResult {
        let input = DescribeEngagementRequest(
            engagementId: engagementId
        )
        return try await self.describeEngagement(input, logger: logger)
    }

    /// Lists details of the engagement to a contact channel.
    @Sendable
    @inlinable
    public func describePage(_ input: DescribePageRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> DescribePageResult {
        try await self.client.execute(
            operation: "DescribePage", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Lists details of the engagement to a contact channel.
    ///
    /// Parameters:
    ///   - pageId: The ID of the engagement to a contact channel.
    ///   - logger: Logger use during operation
    @inlinable
    public func describePage(
        pageId: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> DescribePageResult {
        let input = DescribePageRequest(
            pageId: pageId
        )
        return try await self.describePage(input, logger: logger)
    }

    /// Retrieves information about the specified contact or escalation plan.
    @Sendable
    @inlinable
    public func getContact(_ input: GetContactRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> GetContactResult {
        try await self.client.execute(
            operation: "GetContact", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Retrieves information about the specified contact or escalation plan.
    ///
    /// Parameters:
    ///   - contactId: The Amazon Resource Name (ARN) of the contact or escalation plan.
    ///   - logger: Logger use during operation
    @inlinable
    public func getContact(
        contactId: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> GetContactResult {
        let input = GetContactRequest(
            contactId: contactId
        )
        return try await self.getContact(input, logger: logger)
    }

    /// List details about a specific contact channel.
    @Sendable
    @inlinable
    public func getContactChannel(_ input: GetContactChannelRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> GetContactChannelResult {
        try await self.client.execute(
            operation: "GetContactChannel", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// List details about a specific contact channel.
    ///
    /// Parameters:
    ///   - contactChannelId: The Amazon Resource Name (ARN) of the contact channel you want information about.
    ///   - logger: Logger use during operation
    @inlinable
    public func getContactChannel(
        contactChannelId: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> GetContactChannelResult {
        let input = GetContactChannelRequest(
            contactChannelId: contactChannelId
        )
        return try await self.getContactChannel(input, logger: logger)
    }

    /// Retrieves the resource policies attached to the specified contact or escalation plan.
    @Sendable
    @inlinable
    public func getContactPolicy(_ input: GetContactPolicyRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> GetContactPolicyResult {
        try await self.client.execute(
            operation: "GetContactPolicy", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Retrieves the resource policies attached to the specified contact or escalation plan.
    ///
    /// Parameters:
    ///   - contactArn: The Amazon Resource Name (ARN) of the contact or escalation plan.
    ///   - logger: Logger use during operation
    @inlinable
    public func getContactPolicy(
        contactArn: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> GetContactPolicyResult {
        let input = GetContactPolicyRequest(
            contactArn: contactArn
        )
        return try await self.getContactPolicy(input, logger: logger)
    }

    /// Retrieves information about an on-call rotation.
    @Sendable
    @inlinable
    public func getRotation(_ input: GetRotationRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> GetRotationResult {
        try await self.client.execute(
            operation: "GetRotation", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Retrieves information about an on-call rotation.
    ///
    /// Parameters:
    ///   - rotationId: The Amazon Resource Name (ARN) of the on-call rotation to retrieve information about.
    ///   - logger: Logger use during operation
    @inlinable
    public func getRotation(
        rotationId: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> GetRotationResult {
        let input = GetRotationRequest(
            rotationId: rotationId
        )
        return try await self.getRotation(input, logger: logger)
    }

    /// Retrieves information about an override to an on-call rotation.
    @Sendable
    @inlinable
    public func getRotationOverride(_ input: GetRotationOverrideRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> GetRotationOverrideResult {
        try await self.client.execute(
            operation: "GetRotationOverride", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Retrieves information about an override to an on-call rotation.
    ///
    /// Parameters:
    ///   - rotationId: The Amazon Resource Name (ARN) of the overridden rotation to retrieve information about.
    ///   - rotationOverrideId: The Amazon Resource Name (ARN) of the on-call rotation override to retrieve information about.
    ///   - logger: Logger use during operation
    @inlinable
    public func getRotationOverride(
        rotationId: String,
        rotationOverrideId: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> GetRotationOverrideResult {
        let input = GetRotationOverrideRequest(
            rotationId: rotationId, 
            rotationOverrideId: rotationOverrideId
        )
        return try await self.getRotationOverride(input, logger: logger)
    }

    /// Lists all contact channels for the specified contact.
    @Sendable
    @inlinable
    public func listContactChannels(_ input: ListContactChannelsRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> ListContactChannelsResult {
        try await self.client.execute(
            operation: "ListContactChannels", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Lists all contact channels for the specified contact.
    ///
    /// Parameters:
    ///   - contactId: The Amazon Resource Name (ARN) of the contact.
    ///   - maxResults: The maximum number of contact channels per page.
    ///   - nextToken: The pagination token to continue to the next page of results.
    ///   - logger: Logger use during operation
    @inlinable
    public func listContactChannels(
        contactId: String,
        maxResults: Int? = nil,
        nextToken: String? = nil,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> ListContactChannelsResult {
        let input = ListContactChannelsRequest(
            contactId: contactId, 
            maxResults: maxResults, 
            nextToken: nextToken
        )
        return try await self.listContactChannels(input, logger: logger)
    }

    /// Lists all contacts and escalation plans in Incident Manager.
    @Sendable
    @inlinable
    public func listContacts(_ input: ListContactsRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> ListContactsResult {
        try await self.client.execute(
            operation: "ListContacts", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Lists all contacts and escalation plans in Incident Manager.
    ///
    /// Parameters:
    ///   - aliasPrefix: Used to list only contacts who's aliases start with the specified prefix.
    ///   - maxResults: The maximum number of contacts and escalation plans per page of results.
    ///   - nextToken: The pagination token to continue to the next page of results.
    ///   - type: The type of contact. A contact is type PERSONAL and an escalation plan is type ESCALATION.
    ///   - logger: Logger use during operation
    @inlinable
    public func listContacts(
        aliasPrefix: String? = nil,
        maxResults: Int? = nil,
        nextToken: String? = nil,
        type: ContactType? = nil,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> ListContactsResult {
        let input = ListContactsRequest(
            aliasPrefix: aliasPrefix, 
            maxResults: maxResults, 
            nextToken: nextToken, 
            type: type
        )
        return try await self.listContacts(input, logger: logger)
    }

    /// Lists all engagements that have happened in an incident.
    @Sendable
    @inlinable
    public func listEngagements(_ input: ListEngagementsRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> ListEngagementsResult {
        try await self.client.execute(
            operation: "ListEngagements", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Lists all engagements that have happened in an incident.
    ///
    /// Parameters:
    ///   - incidentId: The Amazon Resource Name (ARN) of the incident you're listing engagements for.
    ///   - maxResults: The maximum number of engagements per page of results.
    ///   - nextToken: The pagination token to continue to the next page of results.
    ///   - timeRangeValue: The time range to lists engagements for an incident.
    ///   - logger: Logger use during operation
    @inlinable
    public func listEngagements(
        incidentId: String? = nil,
        maxResults: Int? = nil,
        nextToken: String? = nil,
        timeRangeValue: TimeRange? = nil,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> ListEngagementsResult {
        let input = ListEngagementsRequest(
            incidentId: incidentId, 
            maxResults: maxResults, 
            nextToken: nextToken, 
            timeRangeValue: timeRangeValue
        )
        return try await self.listEngagements(input, logger: logger)
    }

    /// Lists all of the engagements to contact channels that have been acknowledged.
    @Sendable
    @inlinable
    public func listPageReceipts(_ input: ListPageReceiptsRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> ListPageReceiptsResult {
        try await self.client.execute(
            operation: "ListPageReceipts", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Lists all of the engagements to contact channels that have been acknowledged.
    ///
    /// Parameters:
    ///   - maxResults: The maximum number of acknowledgements per page of results.
    ///   - nextToken: The pagination token to continue to the next page of results.
    ///   - pageId: The Amazon Resource Name (ARN) of the engagement to a specific contact channel.
    ///   - logger: Logger use during operation
    @inlinable
    public func listPageReceipts(
        maxResults: Int? = nil,
        nextToken: String? = nil,
        pageId: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> ListPageReceiptsResult {
        let input = ListPageReceiptsRequest(
            maxResults: maxResults, 
            nextToken: nextToken, 
            pageId: pageId
        )
        return try await self.listPageReceipts(input, logger: logger)
    }

    /// Returns the resolution path of an engagement. For example, the escalation plan engaged in an incident might target an on-call schedule that includes several contacts in a rotation, but just one contact on-call when the incident starts. The resolution path indicates the hierarchy of escalation plan > on-call schedule > contact.
    @Sendable
    @inlinable
    public func listPageResolutions(_ input: ListPageResolutionsRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> ListPageResolutionsResult {
        try await self.client.execute(
            operation: "ListPageResolutions", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Returns the resolution path of an engagement. For example, the escalation plan engaged in an incident might target an on-call schedule that includes several contacts in a rotation, but just one contact on-call when the incident starts. The resolution path indicates the hierarchy of escalation plan > on-call schedule > contact.
    ///
    /// Parameters:
    ///   - nextToken: A token to start the list. Use this token to get the next set of results.
    ///   - pageId: The Amazon Resource Name (ARN) of the contact engaged for the incident.
    ///   - logger: Logger use during operation
    @inlinable
    public func listPageResolutions(
        nextToken: String? = nil,
        pageId: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> ListPageResolutionsResult {
        let input = ListPageResolutionsRequest(
            nextToken: nextToken, 
            pageId: pageId
        )
        return try await self.listPageResolutions(input, logger: logger)
    }

    /// Lists the engagements to a contact's contact channels.
    @Sendable
    @inlinable
    public func listPagesByContact(_ input: ListPagesByContactRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> ListPagesByContactResult {
        try await self.client.execute(
            operation: "ListPagesByContact", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Lists the engagements to a contact's contact channels.
    ///
    /// Parameters:
    ///   - contactId: The Amazon Resource Name (ARN) of the contact you are retrieving engagements for.
    ///   - maxResults: The maximum number of engagements to contact channels to list per page of results.
    ///   - nextToken: The pagination token to continue to the next page of results.
    ///   - logger: Logger use during operation
    @inlinable
    public func listPagesByContact(
        contactId: String,
        maxResults: Int? = nil,
        nextToken: String? = nil,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> ListPagesByContactResult {
        let input = ListPagesByContactRequest(
            contactId: contactId, 
            maxResults: maxResults, 
            nextToken: nextToken
        )
        return try await self.listPagesByContact(input, logger: logger)
    }

    /// Lists the engagements to contact channels that occurred by engaging a contact.
    @Sendable
    @inlinable
    public func listPagesByEngagement(_ input: ListPagesByEngagementRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> ListPagesByEngagementResult {
        try await self.client.execute(
            operation: "ListPagesByEngagement", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Lists the engagements to contact channels that occurred by engaging a contact.
    ///
    /// Parameters:
    ///   - engagementId: The Amazon Resource Name (ARN) of the engagement.
    ///   - maxResults: The maximum number of engagements to contact channels to list per page of results.
    ///   - nextToken: The pagination token to continue to the next page of results.
    ///   - logger: Logger use during operation
    @inlinable
    public func listPagesByEngagement(
        engagementId: String,
        maxResults: Int? = nil,
        nextToken: String? = nil,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> ListPagesByEngagementResult {
        let input = ListPagesByEngagementRequest(
            engagementId: engagementId, 
            maxResults: maxResults, 
            nextToken: nextToken
        )
        return try await self.listPagesByEngagement(input, logger: logger)
    }

    /// Returns a list of shifts based on rotation configuration parameters.  The Incident Manager primarily uses this operation to populate the Preview calendar. It is not typically run by end users.
    @Sendable
    @inlinable
    public func listPreviewRotationShifts(_ input: ListPreviewRotationShiftsRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> ListPreviewRotationShiftsResult {
        try await self.client.execute(
            operation: "ListPreviewRotationShifts", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Returns a list of shifts based on rotation configuration parameters.  The Incident Manager primarily uses this operation to populate the Preview calendar. It is not typically run by end users.
    ///
    /// Parameters:
    ///   - endTime: The date and time a rotation shift would end.
    ///   - maxResults: The maximum number of items to return for this call. The call also returns a token that can be specified in a subsequent call to get the next set of results.
    ///   - members: The contacts that would be assigned to a rotation.
    ///   - nextToken: A token to start the list. This token is used to get the next set of results.
    ///   - overrides: Information about changes that would be made in a rotation override.
    ///   - recurrence: Information about how long a rotation would last before restarting at the beginning of the shift order.
    ///   - rotationStartTime: The date and time a rotation would begin. The first shift is calculated from this date and time.
    ///   - startTime: Used to filter the range of calculated shifts before sending the response back to the user.
    ///   - timeZoneId: The time zone the rotation’s activity would be based on, in Internet Assigned Numbers Authority (IANA) format. For example: "America/Los_Angeles", "UTC", or "Asia/Seoul".
    ///   - logger: Logger use during operation
    @inlinable
    public func listPreviewRotationShifts(
        endTime: Date,
        maxResults: Int? = nil,
        members: [String],
        nextToken: String? = nil,
        overrides: [PreviewOverride]? = nil,
        recurrence: RecurrenceSettings,
        rotationStartTime: Date? = nil,
        startTime: Date? = nil,
        timeZoneId: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> ListPreviewRotationShiftsResult {
        let input = ListPreviewRotationShiftsRequest(
            endTime: endTime, 
            maxResults: maxResults, 
            members: members, 
            nextToken: nextToken, 
            overrides: overrides, 
            recurrence: recurrence, 
            rotationStartTime: rotationStartTime, 
            startTime: startTime, 
            timeZoneId: timeZoneId
        )
        return try await self.listPreviewRotationShifts(input, logger: logger)
    }

    /// Retrieves a list of overrides currently specified for an on-call rotation.
    @Sendable
    @inlinable
    public func listRotationOverrides(_ input: ListRotationOverridesRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> ListRotationOverridesResult {
        try await self.client.execute(
            operation: "ListRotationOverrides", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Retrieves a list of overrides currently specified for an on-call rotation.
    ///
    /// Parameters:
    ///   - endTime: The date and time for the end of a time range for listing overrides.
    ///   - maxResults: The maximum number of items to return for this call. The call also returns a token that you can specify in a subsequent call to get the next set of results.
    ///   - nextToken: A token to start the list. Use this token to get the next set of results.
    ///   - rotationId: The Amazon Resource Name (ARN) of the rotation to retrieve information about.
    ///   - startTime: The date and time for the beginning of a time range for listing overrides.
    ///   - logger: Logger use during operation
    @inlinable
    public func listRotationOverrides(
        endTime: Date,
        maxResults: Int? = nil,
        nextToken: String? = nil,
        rotationId: String,
        startTime: Date,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> ListRotationOverridesResult {
        let input = ListRotationOverridesRequest(
            endTime: endTime, 
            maxResults: maxResults, 
            nextToken: nextToken, 
            rotationId: rotationId, 
            startTime: startTime
        )
        return try await self.listRotationOverrides(input, logger: logger)
    }

    /// Returns a list of shifts generated by an existing rotation in the system.
    @Sendable
    @inlinable
    public func listRotationShifts(_ input: ListRotationShiftsRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> ListRotationShiftsResult {
        try await self.client.execute(
            operation: "ListRotationShifts", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Returns a list of shifts generated by an existing rotation in the system.
    ///
    /// Parameters:
    ///   - endTime: The date and time for the end of the time range to list shifts for.
    ///   - maxResults: The maximum number of items to return for this call. The call also returns a token that you can specify in a subsequent call to get the next set of results.
    ///   - nextToken: A token to start the list. Use this token to get the next set of results.
    ///   - rotationId: The Amazon Resource Name (ARN) of the rotation to retrieve shift information about.
    ///   - startTime: The date and time for the beginning of the time range to list shifts for.
    ///   - logger: Logger use during operation
    @inlinable
    public func listRotationShifts(
        endTime: Date,
        maxResults: Int? = nil,
        nextToken: String? = nil,
        rotationId: String,
        startTime: Date? = nil,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> ListRotationShiftsResult {
        let input = ListRotationShiftsRequest(
            endTime: endTime, 
            maxResults: maxResults, 
            nextToken: nextToken, 
            rotationId: rotationId, 
            startTime: startTime
        )
        return try await self.listRotationShifts(input, logger: logger)
    }

    /// Retrieves a list of on-call rotations.
    @Sendable
    @inlinable
    public func listRotations(_ input: ListRotationsRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> ListRotationsResult {
        try await self.client.execute(
            operation: "ListRotations", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Retrieves a list of on-call rotations.
    ///
    /// Parameters:
    ///   - maxResults: The maximum number of items to return for this call. The call also returns a token that you can specify in a subsequent call to get the next set of results.
    ///   - nextToken: A token to start the list. Use this token to get the next set of results.
    ///   - rotationNamePrefix: A filter to include rotations in list results based on their common prefix. For example, entering prod returns a list of all rotation names that begin with prod, such as production and prod-1.
    ///   - logger: Logger use during operation
    @inlinable
    public func listRotations(
        maxResults: Int? = nil,
        nextToken: String? = nil,
        rotationNamePrefix: String? = nil,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> ListRotationsResult {
        let input = ListRotationsRequest(
            maxResults: maxResults, 
            nextToken: nextToken, 
            rotationNamePrefix: rotationNamePrefix
        )
        return try await self.listRotations(input, logger: logger)
    }

    /// Lists the tags of an escalation plan or contact.
    @Sendable
    @inlinable
    public func listTagsForResource(_ input: ListTagsForResourceRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> ListTagsForResourceResult {
        try await self.client.execute(
            operation: "ListTagsForResource", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Lists the tags of an escalation plan or contact.
    ///
    /// Parameters:
    ///   - resourceARN: The Amazon Resource Name (ARN) of the contact or escalation plan.
    ///   - logger: Logger use during operation
    @inlinable
    public func listTagsForResource(
        resourceARN: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> ListTagsForResourceResult {
        let input = ListTagsForResourceRequest(
            resourceARN: resourceARN
        )
        return try await self.listTagsForResource(input, logger: logger)
    }

    /// Adds a resource policy to the specified contact or escalation plan. The resource policy is used to share the contact or escalation plan using Resource Access Manager (RAM). For more information about cross-account sharing, see Setting up cross-account functionality.
    @Sendable
    @inlinable
    public func putContactPolicy(_ input: PutContactPolicyRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> PutContactPolicyResult {
        try await self.client.execute(
            operation: "PutContactPolicy", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Adds a resource policy to the specified contact or escalation plan. The resource policy is used to share the contact or escalation plan using Resource Access Manager (RAM). For more information about cross-account sharing, see Setting up cross-account functionality.
    ///
    /// Parameters:
    ///   - contactArn: The Amazon Resource Name (ARN) of the contact or escalation plan.
    ///   - policy: Details of the resource policy.
    ///   - logger: Logger use during operation
    @inlinable
    public func putContactPolicy(
        contactArn: String,
        policy: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> PutContactPolicyResult {
        let input = PutContactPolicyRequest(
            contactArn: contactArn, 
            policy: policy
        )
        return try await self.putContactPolicy(input, logger: logger)
    }

    /// Sends an activation code to a contact channel. The contact can use this code to activate the contact channel in the console or with the ActivateChannel operation. Incident Manager can't engage a contact channel until it has been activated.
    @Sendable
    @inlinable
    public func sendActivationCode(_ input: SendActivationCodeRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> SendActivationCodeResult {
        try await self.client.execute(
            operation: "SendActivationCode", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Sends an activation code to a contact channel. The contact can use this code to activate the contact channel in the console or with the ActivateChannel operation. Incident Manager can't engage a contact channel until it has been activated.
    ///
    /// Parameters:
    ///   - contactChannelId: The Amazon Resource Name (ARN) of the contact channel.
    ///   - logger: Logger use during operation
    @inlinable
    public func sendActivationCode(
        contactChannelId: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> SendActivationCodeResult {
        let input = SendActivationCodeRequest(
            contactChannelId: contactChannelId
        )
        return try await self.sendActivationCode(input, logger: logger)
    }

    /// Starts an engagement to a contact or escalation plan. The engagement engages each contact specified in the incident.
    @Sendable
    @inlinable
    public func startEngagement(_ input: StartEngagementRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> StartEngagementResult {
        try await self.client.execute(
            operation: "StartEngagement", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Starts an engagement to a contact or escalation plan. The engagement engages each contact specified in the incident.
    ///
    /// Parameters:
    ///   - contactId: The Amazon Resource Name (ARN) of the contact being engaged.
    ///   - content: The secure content of the message that was sent to the contact. Use this field for engagements to VOICE or EMAIL.
    ///   - idempotencyToken: A token ensuring that the operation is called only once with the specified details.
    ///   - incidentId: The ARN of the incident that the engagement is part of.
    ///   - publicContent: The insecure content of the message that was sent to the contact. Use this field for engagements to SMS.
    ///   - publicSubject: The insecure subject of the message that was sent to the contact. Use this field for engagements to SMS.
    ///   - sender: The user that started the engagement.
    ///   - subject: The secure subject of the message that was sent to the contact. Use this field for engagements to VOICE or EMAIL.
    ///   - logger: Logger use during operation
    @inlinable
    public func startEngagement(
        contactId: String,
        content: String,
        idempotencyToken: String? = StartEngagementRequest.idempotencyToken(),
        incidentId: String? = nil,
        publicContent: String? = nil,
        publicSubject: String? = nil,
        sender: String,
        subject: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> StartEngagementResult {
        let input = StartEngagementRequest(
            contactId: contactId, 
            content: content, 
            idempotencyToken: idempotencyToken, 
            incidentId: incidentId, 
            publicContent: publicContent, 
            publicSubject: publicSubject, 
            sender: sender, 
            subject: subject
        )
        return try await self.startEngagement(input, logger: logger)
    }

    /// Stops an engagement before it finishes the final stage of the escalation plan or engagement plan. Further contacts aren't engaged.
    @Sendable
    @inlinable
    public func stopEngagement(_ input: StopEngagementRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> StopEngagementResult {
        try await self.client.execute(
            operation: "StopEngagement", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Stops an engagement before it finishes the final stage of the escalation plan or engagement plan. Further contacts aren't engaged.
    ///
    /// Parameters:
    ///   - engagementId: The Amazon Resource Name (ARN) of the engagement.
    ///   - reason: The reason that you're stopping the engagement.
    ///   - logger: Logger use during operation
    @inlinable
    public func stopEngagement(
        engagementId: String,
        reason: String? = nil,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> StopEngagementResult {
        let input = StopEngagementRequest(
            engagementId: engagementId, 
            reason: reason
        )
        return try await self.stopEngagement(input, logger: logger)
    }

    /// Tags a contact or escalation plan. You can tag only contacts and escalation plans in the first region of your replication set.
    @Sendable
    @inlinable
    public func tagResource(_ input: TagResourceRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> TagResourceResult {
        try await self.client.execute(
            operation: "TagResource", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Tags a contact or escalation plan. You can tag only contacts and escalation plans in the first region of your replication set.
    ///
    /// Parameters:
    ///   - resourceARN: The Amazon Resource Name (ARN) of the contact or escalation plan.
    ///   - tags: A list of tags that you are adding to the contact or escalation plan.
    ///   - logger: Logger use during operation
    @inlinable
    public func tagResource(
        resourceARN: String,
        tags: [Tag],
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> TagResourceResult {
        let input = TagResourceRequest(
            resourceARN: resourceARN, 
            tags: tags
        )
        return try await self.tagResource(input, logger: logger)
    }

    /// Removes tags from the specified resource.
    @Sendable
    @inlinable
    public func untagResource(_ input: UntagResourceRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> UntagResourceResult {
        try await self.client.execute(
            operation: "UntagResource", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Removes tags from the specified resource.
    ///
    /// Parameters:
    ///   - resourceARN: The Amazon Resource Name (ARN) of the contact or escalation plan.
    ///   - tagKeys: The key of the tag that you want to remove.
    ///   - logger: Logger use during operation
    @inlinable
    public func untagResource(
        resourceARN: String,
        tagKeys: [String],
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> UntagResourceResult {
        let input = UntagResourceRequest(
            resourceARN: resourceARN, 
            tagKeys: tagKeys
        )
        return try await self.untagResource(input, logger: logger)
    }

    /// Updates the contact or escalation plan specified.
    @Sendable
    @inlinable
    public func updateContact(_ input: UpdateContactRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> UpdateContactResult {
        try await self.client.execute(
            operation: "UpdateContact", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Updates the contact or escalation plan specified.
    ///
    /// Parameters:
    ///   - contactId: The Amazon Resource Name (ARN) of the contact or escalation plan you're updating.
    ///   - displayName: The full name of the contact or escalation plan.
    ///   - plan: A list of stages. A contact has an engagement plan with stages for specified contact channels. An escalation plan uses these stages to contact specified contacts.
    ///   - logger: Logger use during operation
    @inlinable
    public func updateContact(
        contactId: String,
        displayName: String? = nil,
        plan: Plan? = nil,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> UpdateContactResult {
        let input = UpdateContactRequest(
            contactId: contactId, 
            displayName: displayName, 
            plan: plan
        )
        return try await self.updateContact(input, logger: logger)
    }

    /// Updates a contact's contact channel.
    @Sendable
    @inlinable
    public func updateContactChannel(_ input: UpdateContactChannelRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> UpdateContactChannelResult {
        try await self.client.execute(
            operation: "UpdateContactChannel", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Updates a contact's contact channel.
    ///
    /// Parameters:
    ///   - contactChannelId: The Amazon Resource Name (ARN) of the contact channel you want to update.
    ///   - deliveryAddress: The details that Incident Manager uses when trying to engage the contact channel.
    ///   - name: The name of the contact channel.
    ///   - logger: Logger use during operation
    @inlinable
    public func updateContactChannel(
        contactChannelId: String,
        deliveryAddress: ContactChannelAddress? = nil,
        name: String? = nil,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> UpdateContactChannelResult {
        let input = UpdateContactChannelRequest(
            contactChannelId: contactChannelId, 
            deliveryAddress: deliveryAddress, 
            name: name
        )
        return try await self.updateContactChannel(input, logger: logger)
    }

    /// Updates the information specified for an on-call rotation.
    @Sendable
    @inlinable
    public func updateRotation(_ input: UpdateRotationRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> UpdateRotationResult {
        try await self.client.execute(
            operation: "UpdateRotation", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Updates the information specified for an on-call rotation.
    ///
    /// Parameters:
    ///   - contactIds: The Amazon Resource Names (ARNs) of the contacts to include in the updated rotation.  The order in which you list the contacts is their shift order in the rotation schedule.
    ///   - recurrence: Information about how long the updated rotation lasts before restarting at the beginning of the shift order.
    ///   - rotationId: The Amazon Resource Name (ARN) of the rotation to update.
    ///   - startTime: The date and time the rotation goes into effect.
    ///   - timeZoneId: The time zone to base the updated rotation’s activity on, in Internet Assigned Numbers Authority (IANA) format. For example: "America/Los_Angeles", "UTC", or "Asia/Seoul". For more information, see the Time Zone Database on the IANA website.  Designators for time zones that don’t support Daylight Savings Time Rules, such as Pacific Standard Time (PST) and Pacific Daylight Time (PDT), aren't supported.
    ///   - logger: Logger use during operation
    @inlinable
    public func updateRotation(
        contactIds: [String]? = nil,
        recurrence: RecurrenceSettings,
        rotationId: String,
        startTime: Date? = nil,
        timeZoneId: String? = nil,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> UpdateRotationResult {
        let input = UpdateRotationRequest(
            contactIds: contactIds, 
            recurrence: recurrence, 
            rotationId: rotationId, 
            startTime: startTime, 
            timeZoneId: timeZoneId
        )
        return try await self.updateRotation(input, logger: logger)
    }
}

extension SSMContacts {
    /// Initializer required by `AWSService.with(middlewares:timeout:byteBufferAllocator:options)`. You are not able to use this initializer directly as there are not public
    /// initializers for `AWSServiceConfig.Patch`. Please use `AWSService.with(middlewares:timeout:byteBufferAllocator:options)` instead.
    public init(from: SSMContacts, patch: AWSServiceConfig.Patch) {
        self.client = from.client
        self.config = from.config.with(patch: patch)
    }
}

// MARK: Paginators

@available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *)
extension SSMContacts {
    /// Return PaginatorSequence for operation ``listContactChannels(_:logger:)``.
    ///
    /// - Parameters:
    ///   - input: Input for operation
    ///   - logger: Logger used for logging
    @inlinable
    public func listContactChannelsPaginator(
        _ input: ListContactChannelsRequest,
        logger: Logger = AWSClient.loggingDisabled
    ) -> AWSClient.PaginatorSequence<ListContactChannelsRequest, ListContactChannelsResult> {
        return .init(
            input: input,
            command: self.listContactChannels,
            inputKey: \ListContactChannelsRequest.nextToken,
            outputKey: \ListContactChannelsResult.nextToken,
            logger: logger
        )
    }
    /// Return PaginatorSequence for operation ``listContactChannels(_:logger:)``.
    ///
    /// - Parameters:
    ///   - contactId: The Amazon Resource Name (ARN) of the contact.
    ///   - maxResults: The maximum number of contact channels per page.
    ///   - logger: Logger used for logging
    @inlinable
    public func listContactChannelsPaginator(
        contactId: String,
        maxResults: Int? = nil,
        logger: Logger = AWSClient.loggingDisabled        
    ) -> AWSClient.PaginatorSequence<ListContactChannelsRequest, ListContactChannelsResult> {
        let input = ListContactChannelsRequest(
            contactId: contactId, 
            maxResults: maxResults
        )
        return self.listContactChannelsPaginator(input, logger: logger)
    }

    /// Return PaginatorSequence for operation ``listContacts(_:logger:)``.
    ///
    /// - Parameters:
    ///   - input: Input for operation
    ///   - logger: Logger used for logging
    @inlinable
    public func listContactsPaginator(
        _ input: ListContactsRequest,
        logger: Logger = AWSClient.loggingDisabled
    ) -> AWSClient.PaginatorSequence<ListContactsRequest, ListContactsResult> {
        return .init(
            input: input,
            command: self.listContacts,
            inputKey: \ListContactsRequest.nextToken,
            outputKey: \ListContactsResult.nextToken,
            logger: logger
        )
    }
    /// Return PaginatorSequence for operation ``listContacts(_:logger:)``.
    ///
    /// - Parameters:
    ///   - aliasPrefix: Used to list only contacts who's aliases start with the specified prefix.
    ///   - maxResults: The maximum number of contacts and escalation plans per page of results.
    ///   - type: The type of contact. A contact is type PERSONAL and an escalation plan is type ESCALATION.
    ///   - logger: Logger used for logging
    @inlinable
    public func listContactsPaginator(
        aliasPrefix: String? = nil,
        maxResults: Int? = nil,
        type: ContactType? = nil,
        logger: Logger = AWSClient.loggingDisabled        
    ) -> AWSClient.PaginatorSequence<ListContactsRequest, ListContactsResult> {
        let input = ListContactsRequest(
            aliasPrefix: aliasPrefix, 
            maxResults: maxResults, 
            type: type
        )
        return self.listContactsPaginator(input, logger: logger)
    }

    /// Return PaginatorSequence for operation ``listEngagements(_:logger:)``.
    ///
    /// - Parameters:
    ///   - input: Input for operation
    ///   - logger: Logger used for logging
    @inlinable
    public func listEngagementsPaginator(
        _ input: ListEngagementsRequest,
        logger: Logger = AWSClient.loggingDisabled
    ) -> AWSClient.PaginatorSequence<ListEngagementsRequest, ListEngagementsResult> {
        return .init(
            input: input,
            command: self.listEngagements,
            inputKey: \ListEngagementsRequest.nextToken,
            outputKey: \ListEngagementsResult.nextToken,
            logger: logger
        )
    }
    /// Return PaginatorSequence for operation ``listEngagements(_:logger:)``.
    ///
    /// - Parameters:
    ///   - incidentId: The Amazon Resource Name (ARN) of the incident you're listing engagements for.
    ///   - maxResults: The maximum number of engagements per page of results.
    ///   - timeRangeValue: The time range to lists engagements for an incident.
    ///   - logger: Logger used for logging
    @inlinable
    public func listEngagementsPaginator(
        incidentId: String? = nil,
        maxResults: Int? = nil,
        timeRangeValue: TimeRange? = nil,
        logger: Logger = AWSClient.loggingDisabled        
    ) -> AWSClient.PaginatorSequence<ListEngagementsRequest, ListEngagementsResult> {
        let input = ListEngagementsRequest(
            incidentId: incidentId, 
            maxResults: maxResults, 
            timeRangeValue: timeRangeValue
        )
        return self.listEngagementsPaginator(input, logger: logger)
    }

    /// Return PaginatorSequence for operation ``listPageReceipts(_:logger:)``.
    ///
    /// - Parameters:
    ///   - input: Input for operation
    ///   - logger: Logger used for logging
    @inlinable
    public func listPageReceiptsPaginator(
        _ input: ListPageReceiptsRequest,
        logger: Logger = AWSClient.loggingDisabled
    ) -> AWSClient.PaginatorSequence<ListPageReceiptsRequest, ListPageReceiptsResult> {
        return .init(
            input: input,
            command: self.listPageReceipts,
            inputKey: \ListPageReceiptsRequest.nextToken,
            outputKey: \ListPageReceiptsResult.nextToken,
            logger: logger
        )
    }
    /// Return PaginatorSequence for operation ``listPageReceipts(_:logger:)``.
    ///
    /// - Parameters:
    ///   - maxResults: The maximum number of acknowledgements per page of results.
    ///   - pageId: The Amazon Resource Name (ARN) of the engagement to a specific contact channel.
    ///   - logger: Logger used for logging
    @inlinable
    public func listPageReceiptsPaginator(
        maxResults: Int? = nil,
        pageId: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) -> AWSClient.PaginatorSequence<ListPageReceiptsRequest, ListPageReceiptsResult> {
        let input = ListPageReceiptsRequest(
            maxResults: maxResults, 
            pageId: pageId
        )
        return self.listPageReceiptsPaginator(input, logger: logger)
    }

    /// Return PaginatorSequence for operation ``listPageResolutions(_:logger:)``.
    ///
    /// - Parameters:
    ///   - input: Input for operation
    ///   - logger: Logger used for logging
    @inlinable
    public func listPageResolutionsPaginator(
        _ input: ListPageResolutionsRequest,
        logger: Logger = AWSClient.loggingDisabled
    ) -> AWSClient.PaginatorSequence<ListPageResolutionsRequest, ListPageResolutionsResult> {
        return .init(
            input: input,
            command: self.listPageResolutions,
            inputKey: \ListPageResolutionsRequest.nextToken,
            outputKey: \ListPageResolutionsResult.nextToken,
            logger: logger
        )
    }
    /// Return PaginatorSequence for operation ``listPageResolutions(_:logger:)``.
    ///
    /// - Parameters:
    ///   - pageId: The Amazon Resource Name (ARN) of the contact engaged for the incident.
    ///   - logger: Logger used for logging
    @inlinable
    public func listPageResolutionsPaginator(
        pageId: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) -> AWSClient.PaginatorSequence<ListPageResolutionsRequest, ListPageResolutionsResult> {
        let input = ListPageResolutionsRequest(
            pageId: pageId
        )
        return self.listPageResolutionsPaginator(input, logger: logger)
    }

    /// Return PaginatorSequence for operation ``listPagesByContact(_:logger:)``.
    ///
    /// - Parameters:
    ///   - input: Input for operation
    ///   - logger: Logger used for logging
    @inlinable
    public func listPagesByContactPaginator(
        _ input: ListPagesByContactRequest,
        logger: Logger = AWSClient.loggingDisabled
    ) -> AWSClient.PaginatorSequence<ListPagesByContactRequest, ListPagesByContactResult> {
        return .init(
            input: input,
            command: self.listPagesByContact,
            inputKey: \ListPagesByContactRequest.nextToken,
            outputKey: \ListPagesByContactResult.nextToken,
            logger: logger
        )
    }
    /// Return PaginatorSequence for operation ``listPagesByContact(_:logger:)``.
    ///
    /// - Parameters:
    ///   - contactId: The Amazon Resource Name (ARN) of the contact you are retrieving engagements for.
    ///   - maxResults: The maximum number of engagements to contact channels to list per page of results.
    ///   - logger: Logger used for logging
    @inlinable
    public func listPagesByContactPaginator(
        contactId: String,
        maxResults: Int? = nil,
        logger: Logger = AWSClient.loggingDisabled        
    ) -> AWSClient.PaginatorSequence<ListPagesByContactRequest, ListPagesByContactResult> {
        let input = ListPagesByContactRequest(
            contactId: contactId, 
            maxResults: maxResults
        )
        return self.listPagesByContactPaginator(input, logger: logger)
    }

    /// Return PaginatorSequence for operation ``listPagesByEngagement(_:logger:)``.
    ///
    /// - Parameters:
    ///   - input: Input for operation
    ///   - logger: Logger used for logging
    @inlinable
    public func listPagesByEngagementPaginator(
        _ input: ListPagesByEngagementRequest,
        logger: Logger = AWSClient.loggingDisabled
    ) -> AWSClient.PaginatorSequence<ListPagesByEngagementRequest, ListPagesByEngagementResult> {
        return .init(
            input: input,
            command: self.listPagesByEngagement,
            inputKey: \ListPagesByEngagementRequest.nextToken,
            outputKey: \ListPagesByEngagementResult.nextToken,
            logger: logger
        )
    }
    /// Return PaginatorSequence for operation ``listPagesByEngagement(_:logger:)``.
    ///
    /// - Parameters:
    ///   - engagementId: The Amazon Resource Name (ARN) of the engagement.
    ///   - maxResults: The maximum number of engagements to contact channels to list per page of results.
    ///   - logger: Logger used for logging
    @inlinable
    public func listPagesByEngagementPaginator(
        engagementId: String,
        maxResults: Int? = nil,
        logger: Logger = AWSClient.loggingDisabled        
    ) -> AWSClient.PaginatorSequence<ListPagesByEngagementRequest, ListPagesByEngagementResult> {
        let input = ListPagesByEngagementRequest(
            engagementId: engagementId, 
            maxResults: maxResults
        )
        return self.listPagesByEngagementPaginator(input, logger: logger)
    }

    /// Return PaginatorSequence for operation ``listPreviewRotationShifts(_:logger:)``.
    ///
    /// - Parameters:
    ///   - input: Input for operation
    ///   - logger: Logger used for logging
    @inlinable
    public func listPreviewRotationShiftsPaginator(
        _ input: ListPreviewRotationShiftsRequest,
        logger: Logger = AWSClient.loggingDisabled
    ) -> AWSClient.PaginatorSequence<ListPreviewRotationShiftsRequest, ListPreviewRotationShiftsResult> {
        return .init(
            input: input,
            command: self.listPreviewRotationShifts,
            inputKey: \ListPreviewRotationShiftsRequest.nextToken,
            outputKey: \ListPreviewRotationShiftsResult.nextToken,
            logger: logger
        )
    }
    /// Return PaginatorSequence for operation ``listPreviewRotationShifts(_:logger:)``.
    ///
    /// - Parameters:
    ///   - endTime: The date and time a rotation shift would end.
    ///   - maxResults: The maximum number of items to return for this call. The call also returns a token that can be specified in a subsequent call to get the next set of results.
    ///   - members: The contacts that would be assigned to a rotation.
    ///   - overrides: Information about changes that would be made in a rotation override.
    ///   - recurrence: Information about how long a rotation would last before restarting at the beginning of the shift order.
    ///   - rotationStartTime: The date and time a rotation would begin. The first shift is calculated from this date and time.
    ///   - startTime: Used to filter the range of calculated shifts before sending the response back to the user.
    ///   - timeZoneId: The time zone the rotation’s activity would be based on, in Internet Assigned Numbers Authority (IANA) format. For example: "America/Los_Angeles", "UTC", or "Asia/Seoul".
    ///   - logger: Logger used for logging
    @inlinable
    public func listPreviewRotationShiftsPaginator(
        endTime: Date,
        maxResults: Int? = nil,
        members: [String],
        overrides: [PreviewOverride]? = nil,
        recurrence: RecurrenceSettings,
        rotationStartTime: Date? = nil,
        startTime: Date? = nil,
        timeZoneId: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) -> AWSClient.PaginatorSequence<ListPreviewRotationShiftsRequest, ListPreviewRotationShiftsResult> {
        let input = ListPreviewRotationShiftsRequest(
            endTime: endTime, 
            maxResults: maxResults, 
            members: members, 
            overrides: overrides, 
            recurrence: recurrence, 
            rotationStartTime: rotationStartTime, 
            startTime: startTime, 
            timeZoneId: timeZoneId
        )
        return self.listPreviewRotationShiftsPaginator(input, logger: logger)
    }

    /// Return PaginatorSequence for operation ``listRotationOverrides(_:logger:)``.
    ///
    /// - Parameters:
    ///   - input: Input for operation
    ///   - logger: Logger used for logging
    @inlinable
    public func listRotationOverridesPaginator(
        _ input: ListRotationOverridesRequest,
        logger: Logger = AWSClient.loggingDisabled
    ) -> AWSClient.PaginatorSequence<ListRotationOverridesRequest, ListRotationOverridesResult> {
        return .init(
            input: input,
            command: self.listRotationOverrides,
            inputKey: \ListRotationOverridesRequest.nextToken,
            outputKey: \ListRotationOverridesResult.nextToken,
            logger: logger
        )
    }
    /// Return PaginatorSequence for operation ``listRotationOverrides(_:logger:)``.
    ///
    /// - Parameters:
    ///   - endTime: The date and time for the end of a time range for listing overrides.
    ///   - maxResults: The maximum number of items to return for this call. The call also returns a token that you can specify in a subsequent call to get the next set of results.
    ///   - rotationId: The Amazon Resource Name (ARN) of the rotation to retrieve information about.
    ///   - startTime: The date and time for the beginning of a time range for listing overrides.
    ///   - logger: Logger used for logging
    @inlinable
    public func listRotationOverridesPaginator(
        endTime: Date,
        maxResults: Int? = nil,
        rotationId: String,
        startTime: Date,
        logger: Logger = AWSClient.loggingDisabled        
    ) -> AWSClient.PaginatorSequence<ListRotationOverridesRequest, ListRotationOverridesResult> {
        let input = ListRotationOverridesRequest(
            endTime: endTime, 
            maxResults: maxResults, 
            rotationId: rotationId, 
            startTime: startTime
        )
        return self.listRotationOverridesPaginator(input, logger: logger)
    }

    /// Return PaginatorSequence for operation ``listRotationShifts(_:logger:)``.
    ///
    /// - Parameters:
    ///   - input: Input for operation
    ///   - logger: Logger used for logging
    @inlinable
    public func listRotationShiftsPaginator(
        _ input: ListRotationShiftsRequest,
        logger: Logger = AWSClient.loggingDisabled
    ) -> AWSClient.PaginatorSequence<ListRotationShiftsRequest, ListRotationShiftsResult> {
        return .init(
            input: input,
            command: self.listRotationShifts,
            inputKey: \ListRotationShiftsRequest.nextToken,
            outputKey: \ListRotationShiftsResult.nextToken,
            logger: logger
        )
    }
    /// Return PaginatorSequence for operation ``listRotationShifts(_:logger:)``.
    ///
    /// - Parameters:
    ///   - endTime: The date and time for the end of the time range to list shifts for.
    ///   - maxResults: The maximum number of items to return for this call. The call also returns a token that you can specify in a subsequent call to get the next set of results.
    ///   - rotationId: The Amazon Resource Name (ARN) of the rotation to retrieve shift information about.
    ///   - startTime: The date and time for the beginning of the time range to list shifts for.
    ///   - logger: Logger used for logging
    @inlinable
    public func listRotationShiftsPaginator(
        endTime: Date,
        maxResults: Int? = nil,
        rotationId: String,
        startTime: Date? = nil,
        logger: Logger = AWSClient.loggingDisabled        
    ) -> AWSClient.PaginatorSequence<ListRotationShiftsRequest, ListRotationShiftsResult> {
        let input = ListRotationShiftsRequest(
            endTime: endTime, 
            maxResults: maxResults, 
            rotationId: rotationId, 
            startTime: startTime
        )
        return self.listRotationShiftsPaginator(input, logger: logger)
    }

    /// Return PaginatorSequence for operation ``listRotations(_:logger:)``.
    ///
    /// - Parameters:
    ///   - input: Input for operation
    ///   - logger: Logger used for logging
    @inlinable
    public func listRotationsPaginator(
        _ input: ListRotationsRequest,
        logger: Logger = AWSClient.loggingDisabled
    ) -> AWSClient.PaginatorSequence<ListRotationsRequest, ListRotationsResult> {
        return .init(
            input: input,
            command: self.listRotations,
            inputKey: \ListRotationsRequest.nextToken,
            outputKey: \ListRotationsResult.nextToken,
            logger: logger
        )
    }
    /// Return PaginatorSequence for operation ``listRotations(_:logger:)``.
    ///
    /// - Parameters:
    ///   - maxResults: The maximum number of items to return for this call. The call also returns a token that you can specify in a subsequent call to get the next set of results.
    ///   - rotationNamePrefix: A filter to include rotations in list results based on their common prefix. For example, entering prod returns a list of all rotation names that begin with prod, such as production and prod-1.
    ///   - logger: Logger used for logging
    @inlinable
    public func listRotationsPaginator(
        maxResults: Int? = nil,
        rotationNamePrefix: String? = nil,
        logger: Logger = AWSClient.loggingDisabled        
    ) -> AWSClient.PaginatorSequence<ListRotationsRequest, ListRotationsResult> {
        let input = ListRotationsRequest(
            maxResults: maxResults, 
            rotationNamePrefix: rotationNamePrefix
        )
        return self.listRotationsPaginator(input, logger: logger)
    }
}

extension SSMContacts.ListContactChannelsRequest: AWSPaginateToken {
    @inlinable
    public func usingPaginationToken(_ token: String) -> SSMContacts.ListContactChannelsRequest {
        return .init(
            contactId: self.contactId,
            maxResults: self.maxResults,
            nextToken: token
        )
    }
}

extension SSMContacts.ListContactsRequest: AWSPaginateToken {
    @inlinable
    public func usingPaginationToken(_ token: String) -> SSMContacts.ListContactsRequest {
        return .init(
            aliasPrefix: self.aliasPrefix,
            maxResults: self.maxResults,
            nextToken: token,
            type: self.type
        )
    }
}

extension SSMContacts.ListEngagementsRequest: AWSPaginateToken {
    @inlinable
    public func usingPaginationToken(_ token: String) -> SSMContacts.ListEngagementsRequest {
        return .init(
            incidentId: self.incidentId,
            maxResults: self.maxResults,
            nextToken: token,
            timeRangeValue: self.timeRangeValue
        )
    }
}

extension SSMContacts.ListPageReceiptsRequest: AWSPaginateToken {
    @inlinable
    public func usingPaginationToken(_ token: String) -> SSMContacts.ListPageReceiptsRequest {
        return .init(
            maxResults: self.maxResults,
            nextToken: token,
            pageId: self.pageId
        )
    }
}

extension SSMContacts.ListPageResolutionsRequest: AWSPaginateToken {
    @inlinable
    public func usingPaginationToken(_ token: String) -> SSMContacts.ListPageResolutionsRequest {
        return .init(
            nextToken: token,
            pageId: self.pageId
        )
    }
}

extension SSMContacts.ListPagesByContactRequest: AWSPaginateToken {
    @inlinable
    public func usingPaginationToken(_ token: String) -> SSMContacts.ListPagesByContactRequest {
        return .init(
            contactId: self.contactId,
            maxResults: self.maxResults,
            nextToken: token
        )
    }
}

extension SSMContacts.ListPagesByEngagementRequest: AWSPaginateToken {
    @inlinable
    public func usingPaginationToken(_ token: String) -> SSMContacts.ListPagesByEngagementRequest {
        return .init(
            engagementId: self.engagementId,
            maxResults: self.maxResults,
            nextToken: token
        )
    }
}

extension SSMContacts.ListPreviewRotationShiftsRequest: AWSPaginateToken {
    @inlinable
    public func usingPaginationToken(_ token: String) -> SSMContacts.ListPreviewRotationShiftsRequest {
        return .init(
            endTime: self.endTime,
            maxResults: self.maxResults,
            members: self.members,
            nextToken: token,
            overrides: self.overrides,
            recurrence: self.recurrence,
            rotationStartTime: self.rotationStartTime,
            startTime: self.startTime,
            timeZoneId: self.timeZoneId
        )
    }
}

extension SSMContacts.ListRotationOverridesRequest: AWSPaginateToken {
    @inlinable
    public func usingPaginationToken(_ token: String) -> SSMContacts.ListRotationOverridesRequest {
        return .init(
            endTime: self.endTime,
            maxResults: self.maxResults,
            nextToken: token,
            rotationId: self.rotationId,
            startTime: self.startTime
        )
    }
}

extension SSMContacts.ListRotationShiftsRequest: AWSPaginateToken {
    @inlinable
    public func usingPaginationToken(_ token: String) -> SSMContacts.ListRotationShiftsRequest {
        return .init(
            endTime: self.endTime,
            maxResults: self.maxResults,
            nextToken: token,
            rotationId: self.rotationId,
            startTime: self.startTime
        )
    }
}

extension SSMContacts.ListRotationsRequest: AWSPaginateToken {
    @inlinable
    public func usingPaginationToken(_ token: String) -> SSMContacts.ListRotationsRequest {
        return .init(
            maxResults: self.maxResults,
            nextToken: token,
            rotationNamePrefix: self.rotationNamePrefix
        )
    }
}
